package cloud.shyidong.core.context;

/**
 * @Description TODO
 * @Author syd
 * @Date 2023/8/28
 */
public class TenantContextHolder extends ContextHolder {
    
    private static final ThreadLocal<TenantContext> tenantContextThreadLocal = new InheritableThreadLocal<>();
    
    public static TenantContext getTenantContext() {
        return tenantContextThreadLocal.get();
    }
    
    public static void setTenantContext(TenantContext tenantContext) {
        tenantContextThreadLocal.set(tenantContext);
    }
    
}
